<{include file="public/header.html"}> 
		<header class="bj-white search-page follow-head">
                    <a href="javascript:;" class="icon-return iconfont title-top title-left" onclick="javascript:history.back(-1);">&#xe604;</a>
                    <h1 class="bar-title">溜珠明细</h1>
                    <!--<a href="" class="bead-share">分享</a>-->
		</header>
		<div class="bead-page mt50">
                    <div class="balance">
                        <p class="num"><{$bbs_account['balance']}></p>
                        <p class="title">溜珠余额</p>
                    </div>
		</div>
		<div class="bead-trading">
                    <table class="bead-table">
                        <thead>
                            <tr>
                                <th style="width:33%;">类型</th><th style="width:33%;">数量</th><th style="width:33%;">时间</th>
                            </tr>
                        </thead>
                        <tbody id='content-list'>
                            <{foreach from=$list item=val}>
                                <tr>
                                    <td><{$val['type']}></td>
                                    <td><{if $val['style'] == 1}>+<{else}>-<{/if}><{$val['num']}></td>
                                    <td><{$val['create_time']}></td>
                                </tr>
                            <{/foreach}>
                        </tbody>
                    </table>
                    <div class="loading" id="noresults" <{if $list}>style="display: none;"<{/if}>>
                    	<div class="has-no load-success empty-follow-data">
							<div class="pic"><img src="<{$style_dir}>/img/none/3.jpg" alt="" /><!--class="list-none"--></div>
							<p>小主，咱们暂无粮草去向~</p>
						</div>
                    </div>
                    <div class="loading" id="loading" style="display: none;">
                        <a class="/*pull-load*/ load-success" href="javascript:;">加载中...</a>
                    </div>
                    <div class="loading" id="nomoreresults" style="display: none;">
                        <a href="javascript:;" class="load-success nomore-load">已经到底啦~~~</a>
                    </div>
		</div>
                <script type="text/javascript" src="/static/js/scrollpagination.js"></script>
		<script type="text/javascript">
                    $(function(){
                        var currentPage = 0;
                        $('#content-list').scrollPagination({
                            'contentPage': "/ajax/get_zhu_detail",
                            'contentData': {
                                'pageIndex': currentPage
                            },
                            'scrollTarget': $(window),
                            'heightOffset': 0,
                            'beforeLoad': function() { // before load function, you can display a preloader div
                                $('#loading').fadeIn('fast');
                                $('#loading').attr('scrollpagination','disabled');
                            },
                            'afterLoad': function(elementsLoaded) { // after loading content, you can use this function to animate your new elements
                                $('#loading').fadeOut('fast');
                                $('#loading').attr('scrollpagination','enabled');
                                if (elementsLoaded.length == 0) {
                                    if($('#content-list tr').length != 0){
                                        $('#nomoreresults').fadeIn('slow');
                                    }
                                    $('#content-list').stopScrollPagination();
                                }else{
                                    currentPage = currentPage + 1;
                                }
                                this.contentData.pageIndex = currentPage;
                                $(elementsLoaded).fadeInWithDelay();
                                
                                if ($('#content-list').children().length > 100) { // if more than 100 results already loaded, then stop pagination (only for testing)
                                    $('#nomoreresults').fadeIn();
                                    $('#content-list').stopScrollPagination();
                                };
                            }
                        });     
                        $.fn.fadeInWithDelay = function() {
                            var delay = 0;
                            return this.each(function() {
                                $(this).delay(delay).animate({
                                    opacity: 1
                                }, 200);
                                delay += 100;
                            });
                        };
                    });
		</script>
<{include file="public/footer.html"}> 